package day2;

public class shuzuinitial {
    public static void main(String[] args) {
        int[] shuzu1 = new int[20];//动态初始化
        String[] shuzu2 = new String[]{"哈", "哦", "五"};//静态初始化
        double[] shuzu3 = {5.6, 7.8, 999.8};//数组静态初始化的省略
        int[] shuzu4;
        shuzu4 = new int[8];//动态初始化分成两步
        float[] shuzu5;
        shuzu5 = new float[]{5.9f,6.8f,999.5f};//静态初始化分成两步
        System.out.println(shuzu5[2]);
        shuzu1[3] = 999;//访问数组元素赋值
        System.out.println(shuzu1[1]);
        System.out.println(shuzu1[3]);
    }
}
